﻿USE [ESRP]
GO

/****** Object:  Table [dbo].[AmixSetup]    Script Date: 06/10/2009 11:53:24 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[AmixSetup](
	[PrimaryKey] [smallint] NOT NULL,
	[LunaCurenta] [smallint] NOT NULL,
	[AnulCurent] [smallint] NOT NULL,
	[CodUnitate] [smallint] NOT NULL,
 CONSTRAINT [PK_AmixSetup] PRIMARY KEY CLUSTERED 
(
	[PrimaryKey] ASC,
	[CodUnitate] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]

GO

ALTER TABLE [dbo].[AmixSetup]  WITH CHECK ADD  CONSTRAINT [FK_AmixSetup_Unitati] FOREIGN KEY([CodUnitate])
REFERENCES [dbo].[Unitati] ([CodUnitate])
GO

ALTER TABLE [dbo].[AmixSetup] CHECK CONSTRAINT [FK_AmixSetup_Unitati]
GO

ALTER TABLE [dbo].[AmixSetup] ADD  CONSTRAINT [DF_AmixSetup_PrimaryKey]  DEFAULT ((0)) FOR [PrimaryKey]
GO

ALTER TABLE [dbo].[AmixSetup] ADD  CONSTRAINT [DF_AmixSetup_LunaCurenta]  DEFAULT ((0)) FOR [LunaCurenta]
GO

ALTER TABLE [dbo].[AmixSetup] ADD  CONSTRAINT [DF_AmixSetup_AnulCurent]  DEFAULT ((0)) FOR [AnulCurent]
GO

ALTER TABLE [dbo].[AmixSetup] ADD  CONSTRAINT [DF_AmixSetup_CodUnitate]  DEFAULT ((0)) FOR [CodUnitate]
GO

